package demo1;

/**
 * @Author GocChin
 * @Date 2021/5/11 11:56
 * @Blog: itdfq.com
 * @QQ: 909256107
 * @Descript:
 */
class MyThread extends Thread{
    @Override
    public void run() {
        System.out.println(currentThread().getName()+"运行了");
    }
}
class Test{
    public static void main(String[] args) {
        MyThread myThread = new MyThread();
        System.out.println(Thread.currentThread().getName()+"：运行了");
        //设置分线程的优先级
       myThread.setPriority(Thread.MAX_PRIORITY);
        myThread.start();
    }
}
